Home } Calculators } Round



A simple function to round a decimal number to any number of decimal places you want just by passing it different values. Neat! Very short code, too!

JavaScript Source Code 2002: Calculators: Round

Simply click inside the window below, use your cursor to highlight the script, and copy (type Control-c or Apple-c) the script into a new file in your text editor (such as Note Pad or Simple Text) and save (Control-s or Apple-s). The script is yours!!!